package com.spring.annotation_jsr330_demo;

import com.spring.annotation_demo.TestBean;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class App {

	public static void main(String[] args) {
		ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("spring.xml");
		String[] beanDefinitionNames = context.getBeanDefinitionNames();
		for (String beanDefinitionName : beanDefinitionNames) {
			System.out.println(beanDefinitionName);
		}

		MyCtr myCtr = (MyCtr) context.getBean("okCtr");
		myCtr.hello();
	}
}
